package com.lark.mapper;


import com.lark.pojo.Role;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface RoleMapper {

    @Select("select * from l_role")
    public List<Role> findAll();
    @Insert("insert into l_role values(#{id},#{rolename},#{roledesc})")
    public void insert(Role role);
    @Select("select * from l_user_role sur,l_role sr where sur.roleId=sr.Id and sur.userId=#{id}")
    public List<Role> findRoleById(Long id);
}
